<?php

class Database {

	public static function connect () {

		include "settings.php";
		include $path['phpBB config'];
		
		return new mysqli($dbhost, $dbuser, $dbpasswd, $dbname);
	}

	public static function ensure_connected (&$db) {
		if (is_null($db))
			$db = self::connect();
	}
}

?>